#ifndef COOLPOOL_SIMULATION_SIMOBJECTS_BALLCOLLISIONHANDLER_H_
#define COOLPOOL_SIMULATION_SIMOBJECTS_BALLCOLLISIONHANDLER_H_

#include "Ball.h"
#include "CollisionHandler.h"
#include "ObjectTypes.h"
#include "Rectangle.h"
#include "RigidBodyFriction.h"

namespace coolpool
{
	class RigidBodyCollisionHandler: public CollisionHandler
	{
	public:

		RigidBodyCollisionHandler();
		RigidBodyCollisionHandler(const RigidBodyCollisionHandler & ball_collision_handler);

		virtual ~RigidBodyCollisionHandler();

		virtual CollisionHandler * clone() const;
		virtual void handle(const Collision * collision) throw (UnexpectedInputException);

	private:

		// Handles collision of a rigid body with the given static rigid body object.
		void handleCollisionWithStatic(const Collision * col);

		// Handles collision of two dynamic rigid objects.
		void handleCollisionWithDynamic(const Collision * collision);
	};
}

#endif
